import request from '@/utils/request';
import qs from "qs";



export async function recordList(params) {
  const limit = params.pageSize;
  const page = params.current;
  const my_params = {
    limit: limit,
    page: page
  };
  Object.assign(params, my_params);
  delete params.current;
  delete params.pageSize;
  params.type = "1";
  return request('/supplyChain/warehouseStock/recordPage', {
    params:params,
    paramsSerializer: params => {
      return qs.stringify(params, { indices: false })
    }
  });
}
export async function exportRecord(params) {
  return request(`/supplyChain/warehouseStock/exportRecord`, {
    method: 'GET',
    responseType: 'blob',
    params:params,
    paramsSerializer: params => {
      return qs.stringify(params, { indices: false })
    }
  });
}
export async function getFiles(data) {
  return request('supplyChain/warehouseStock/getFiles', {
    method: 'POST',
    data
  });
}
